home *** CD-ROM | disk | FTP | other *** search
/ Atari Mega Archive 1 / Atari Mega Archive - Volume 1.iso / lists / mint / l_0799 / 456 < prev    next >
Encoding:
Internet Message Format  |  1994-08-27  |  1.5 KB

  1. From: Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
  2. Date: Fri, 27 Aug 93 10:57:41 +0200
  3. Message-Id: <9308270857.AA05866@issan.informatik.uni-dortmund.de>
  4. To: bjarne@GOEDEL.UNI-MUENSTER.DE
  5. In-Reply-To: <9308270044.AA27271@math.uni-muenster.de> (message from Bjarne Pohlers on Fri, 27 Aug 93 02:44:40 +0200)
  6. Subject: Re: utime()
  7.  
  8. >>>>> On Fri, 27 Aug 93 02:44:40 +0200, Bjarne Pohlers <bjarne@GOEDEL.UNI-MUENSTER.DE> said:
  9. |>  Hello,
  10.  
  11. |>  it seems that the utime-MiNTLIB-call does not work with MiNT 1.09 and
  12. |>  minixfs PL6. I noticed that the Libs use a Fcntl()-call with FUTIME as
  13. |>  a command, but I did not find any docs about FUTIME as a
  14. |>  Fcntl()-command. However, the Minixfs *seems to know about FUTIME (in
  15. |>  minixdev.c) but it does not work :-(
  16.  
  17. |>  Does anyone have an idea whats wrong here?
  18.  
  19. This is a bug in minixfs (i have already reported it). Here is a
  20. patch:
  21.  
  22. --- orig/minixfs/minixdev.c    Sat Jul 24 04:12:32 1993
  23. +++ minixfs/minixdev.c    Wed Aug  4 17:04:10 1993
  24. @@ -561,7 +561,8 @@
  25.        d_inode rip;
  26.        short *timeptr = (short *) buf;
  27.  
  28. -      if( !(f->flags & O_WRONLY) ) return EACCDN;
  29. +      if ((f->flags & O_RWMODE) == O_RDONLY)
  30. +        return EACCDN;
  31.        read_inode (f->fc.index, &rip, f->fc.dev);
  32.        rip.i_atime = Unixtime (timeptr[0], timeptr[1]);
  33.        rip.i_mtime = Unixtime (timeptr[2], timeptr[3]);
  34. @@ -575,7 +576,8 @@
  35.  
  36.        case FTRUNCATE:
  37.      {
  38. -      if( !(f->flags & O_WRONLY) ) return EACCDN;
  39. +      if ((f->flags & O_RWMODE) == O_RDONLY)
  40. +        return EACCDN;
  41.  
  42.        itruncate(f->fc.index,f->fc.dev,*((long *)buf));
  43.  
  44. Regards, Andreas
  45.